#ifndef GLOBAL_H
#define GLOBAL_H

#include <XmlRpcServer.h>
#include <XmlRpcValue.h>
#include <XmlRpcServerMethod.h>
#include <XmlRpcException.h>
#include <memory>
#include "logger.h"

#define CHECK_PARAM_ARRAY if (params.getType() != XmlRpc::XmlRpcValue::TypeArray) { ROS_ERROR("error: param is not array");return;}
#define CHECK_PARAM_SIZE(count) if(params.size() != count) { ROS_ERROR("error: param size is not %d", count); return; }


#define DECLARE_DATA(Class) \
    std::unique_ptr<Class##Data> d; \
    friend class Class##Data;

#endif //GLOBAL_H
